package tqq;

import java.io.BufferedReader;
import java.io.FileReader;
import java.util.ArrayList;
import java.util.List;

public class Test {
	public static void getFile(String path) throws Exception{
		BufferedReader read= new BufferedReader(new FileReader(path));
		List<String> list = new ArrayList<>();
		while (read.read()>-1) {
			list.add(read.readLine());
		}
		
		read.close();
		System.out.println(String.join(",", list));
	}
	
	public static void main(String[] args) {
		try {
			getFile("D:\\1.txt");
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}	
